/*
 * SendSMS.cpp
 *
 *  Created on: 2010-1-14
 *      Author: zet
 */

#include "SendSMS.h"


int SMServer::registFlag=-999;	//注册标志,1 成功

int main(int argc,char **argd)
{

	SMServer sms;

		std::vector<std::string> mobilVector;		//组织所有手机号
		std::vector<std::string> messageVector;		//组织所有短信内容

		int smsReturnflag=-999;
		int sub=0;

		if(argc != 3) {
			printf("Parameter too small,no 3!parameter number=%d\n",argc);
			return 1;
		}
	for(sub=0; sub < argc; sub++) {
		printf("argd[%d]=%s\n",sub,argd[sub]);

	}

	mobilVector.push_back(argd[1]);
	messageVector.push_back(argd[2]);


	smsReturnflag=sms.sendSMS(mobilVector,messageVector);
	if(smsReturnflag == 1) {
		printf("send short message success!\n");
	}else {
		printf("send short message fatlure!\n");
		return 2;
	}
	printf("smsReturnflag=%d\n",smsReturnflag);

	return 0;
}
